package com.example.sringboot_web.filter;


import javax.servlet.*;
import java.io.IOException;

public class myfilter2 implements Filter {
    @Override
    public void init(FilterConfig filterConfig) throws ServletException {
        System.out.println("myfilter2初始化》》》》》》》");
    }

    @Override
    public void doFilter(ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain) throws IOException, ServletException {
        System.out.println("进入myfilter2拦截》》》》》");
        filterChain.doFilter(servletRequest, servletResponse);
        System.out.println("离开myfilter2拦截》》》》》");
    }

    @Override
    public void destroy() {
        System.out.println("myfilter2销毁》》》》》》》");
    }
}
